package com.kelvem.saas.workbanch.ontology.order.event;

import com.kelvem.saas.workbanch.fsm.anno.Fsm;
import com.kelvem.saas.workbanch.fsm.anno.event.RegisterEvent;
import com.kelvem.saas.workbanch.fsm.anno.state.EventState;
import com.kelvem.saas.workbanch.fsm.anno.state.EventStateGroup;
import com.kelvem.saas.workbanch.ontology.order.model.OrdersEntity;
import com.kelvem.saas.workbanch.ontology.order.request.OrdersReq;
import lombok.extern.slf4j.Slf4j;

/**
 * @author kelvem
 */
@Slf4j
@Fsm(entityClazz=OrdersEntity.class)
@EventState(stateCode ="stub_state", stateName ="兼容性测试用状态")
@EventStateGroup(groupCode ="stub_group", groupName ="兼容性测试用状态组", states={"before_shipped", "after_shipped", "start", "stub_state"})
public class OrdersStubEvent {
    
    @RegisterEvent(eventCode ="Orders.stub_event1", eventName="兼容性测试用事件1", srcState="all", dstState="start")
    public void stubEvent1(OrdersReq ordersReq) {
        // do nothing
        log.info("stubEvent1 method do nothing");
    }
    
    @RegisterEvent(eventCode ="Orders.stub_event2", eventName="兼容性测试用事件2", srcState="stub_group", dstState="stub_state")
    public void stubEvent2(OrdersReq ordersReq) {
        // do nothing
        log.info("stubEvent2 method do nothing");
    }
}
